<?php
if ( ! version_compare( '5.0.0', phpversion(), '<' )) {
    echo 'ERROR: Direk requires PHP 5 (found '.phpversion().').' ;
    exit( 1 );
}
if ( ! in_array( "SQLite", get_loaded_extensions())) {
    echo 'ERROR: Direk requires SQLite.' ;
    exit( 1 );
} 


require 'classes/Direk.class.php';

session_start();

$d = new Direk();
$action = $_REQUEST[ 'action' ];
$script_name = basename( $_SERVER[ 'SCRIPT_NAME' ] );

if ( $_REQUEST[ 'id' ] ) {
    $id = $_REQUEST[ 'id' ];
    $contact = $d->get_contact( $id );
}
?>
